package com.gperp.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.gperp.mapper.AsAccountMapper;
import com.gperp.pojo.AsAccount;
import com.gperp.pojo.AsAccountExample;
import com.gperp.service.AccountService;

@Service
public class AccountServiceImpl implements AccountService {
	@Resource
	private AsAccountMapper accountMapper;
	@Override
	public AsAccount queryAccountById(Long id) {
		AsAccountExample example = new AsAccountExample();
		example.createCriteria().andUseridEqualTo(id);
		List<AsAccount> list = accountMapper.selectByExample(example);
		if(list!=null&&list.size()>0){
			return list.get(0);
		}
		return null;
	}

}
